home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 30
/
Aminet 30 (1999)(Schatztruhe)[!][Apr 1999].iso
/
Aminet
/
util
/
sys
/
SavInstaller.lha
/
Installer
/
examples
/
processes.installer
< prev
next >
Wrap
Text File
|
1998-09-14
|
1KB
|
60 lines
(message "\n\nThis is a small performance test :)\n\n"
"There are 4 WHILE loops, all counting from 50000\n"
"down to 0. One time this will be done concurrently\n"
"(for every WHILE one process) and then these WHILE\n"
"loops running one after the other...\n"
"Let`s see, what is faster!"
)
(working "\nPlease be patient - this will take some time.")
; *******************************************************************
(set #before1 (database "time"))
(concurrent-do (
(set i 50000)
(while i (set i (- i 1)))
)
(
(set j 50000)
(while j (set j (- j 1)))
)
(
(set k 50000)
(while k (set k (- k 1)))
)
(
(set l 50000)
(while l (set l (- l 1)))
)
)
(set #after1 (database "time"))
; *******************************************************************
(set #before2 (database "time"))
(
(set i 50000)
(while i (set i (- i 1)))
)
(
(set j 50000)
(while j (set j (- j 1)))
)
(
(set k 50000)
(while k (set k (- k 1)))
)
(
(set l 50000)
(while l (set l (- l 1)))
)
(set #after2 (database "time"))
; *******************************************************************
(message "\nDone...\n\n"
("concurrent: %s - %s\nsequencial: %s - %s" #before1 #after1 #before2 #after2)
)